{
  lib,
  newScope,
  pkgs,
  config,
}:

let
  liftJaneStreet = self: super: super.janeStreet // super;

  mkOcamlPackages =
    ocaml:
    (lib.makeScope newScope (
      self:
      with self;
      {
        inherit ocaml;

        ### A ###
        aches = callPackage ../development/ocaml-modules/aches { };
        aches-lwt = callPackage ../development/ocaml-modules/aches/lwt.nix { };

        afl-persistent = callPackage ../development/ocaml-modules/afl-persistent { };

        alcotest = callPackage ../development/ocaml-modules/alcotest { };

        alcotest-lwt = callPackage ../development/ocaml-modules/alcotest/lwt.nix { };

        alcotest-mirage = callPackage ../development/ocaml-modules/alcotest/mirage.nix { };

        algaeff = callPackage ../development/ocaml-modules/algaeff { };

        alsa = callPackage ../development/ocaml-modules/alsa { };

        ancient = callPackage ../development/ocaml-modules/ancient { };

        amqp-client = callPackage ../development/ocaml-modules/amqp-client { };

        amqp-client-async = callPackage ../development/ocaml-modules/amqp-client/async.nix { };

        amqp-client-lwt = callPackage ../development/ocaml-modules/amqp-client/lwt.nix { };

        angstrom = callPackage ../development/ocaml-modules/angstrom { };

        angstrom-async = callPackage ../development/ocaml-modules/angstrom-async { };

        angstrom-lwt-unix = callPackage ../development/ocaml-modules/angstrom-lwt-unix { };

        angstrom-unix = callPackage ../development/ocaml-modules/angstrom-unix { };

        ansiterminal = callPackage ../development/ocaml-modules/ansiterminal { };

        ao = callPackage ../development/ocaml-modules/ao { };

        apron = callPackage ../development/ocaml-modules/apron { };

        argon2 = callPackage ../development/ocaml-modules/argon2 { };

        arg-complete = callPackage ../development/ocaml-modules/arg-complete { };

        arp = callPackage ../development/ocaml-modules/arp { };

        asai = callPackage ../development/ocaml-modules/asai { };

        asetmap = callPackage ../development/ocaml-modules/asetmap { };

        asn1-combinators = callPackage ../development/ocaml-modules/asn1-combinators { };

        astring = callPackage ../development/ocaml-modules/astring { };

        atd = callPackage ../development/ocaml-modules/atd { };

        atdgen = callPackage ../development/ocaml-modules/atdgen { };

        atdgen-codec-runtime = callPackage ../development/ocaml-modules/atdgen/codec-runtime.nix { };

        atdgen-runtime = callPackage ../development/ocaml-modules/atdgen/runtime.nix { };

        augeas = callPackage ../development/ocaml-modules/augeas {
          inherit (pkgs) augeas;
        };

        awa = callPackage ../development/ocaml-modules/awa { };

        awa-mirage = callPackage ../development/ocaml-modules/awa/mirage.nix { };

        ### B ###

        b0 = callPackage ../development/ocaml-modules/b0 { };

        backoff = callPackage ../development/ocaml-modules/backoff { };

        bap = callPackage ../development/ocaml-modules/bap {
          inherit (pkgs.llvmPackages) llvm;
        };

        base64 = callPackage ../development/ocaml-modules/base64 { };

        batteries = callPackage ../development/ocaml-modules/batteries { };

        bdd = callPackage ../development/ocaml-modules/bdd { };

        benchmark = callPackage ../development/ocaml-modules/benchmark { };

        bencode = callPackage ../development/ocaml-modules/bencode { };

        bheap = callPackage ../development/ocaml-modules/bheap { };

        bigarray-compat = callPackage ../development/ocaml-modules/bigarray-compat { };

        bigarray-overlap = callPackage ../development/ocaml-modules/bigarray-overlap { };

        bigstring = callPackage ../development/ocaml-modules/bigstring { };

        bigstringaf = callPackage ../development/ocaml-modules/bigstringaf { };

        bindlib = callPackage ../development/ocaml-modules/bindlib { };

        biniou = callPackage ../development/ocaml-modules/biniou { };

        binning = callPackage ../development/ocaml-modules/binning { };

        biotk = callPackage ../development/ocaml-modules/biotk { };

        bisect_ppx = callPackage ../development/ocaml-modules/bisect_ppx { };

        bistro = callPackage ../development/ocaml-modules/bistro { };

        bitstring = callPackage ../development/ocaml-modules/bitstring { };

        bitv = callPackage ../development/ocaml-modules/bitv { };

        bitwuzla-cxx = callPackage ../development/ocaml-modules/bitwuzla-cxx { };

        bjack = callPackage ../development/ocaml-modules/bjack { };

        bls12-381 = callPackage ../development/ocaml-modules/bls12-381 { };
        bls12-381-gen = callPackage ../development/ocaml-modules/bls12-381/gen.nix { };

        bls12-381-signature = callPackage ../development/ocaml-modules/bls12-381-signature { };

        bos = callPackage ../development/ocaml-modules/bos { };

        brisk-reconciler = callPackage ../development/ocaml-modules/brisk-reconciler { };

        brr = callPackage ../development/ocaml-modules/brr { };

        bstr = callPackage ../development/ocaml-modules/bstr { };

        bwd = callPackage ../development/ocaml-modules/bwd { };

        bytesrw = callPackage ../development/ocaml-modules/bytesrw { };

        bytestring = callPackage ../development/ocaml-modules/bytestring { };

        bz2 = callPackage ../development/ocaml-modules/bz2 { };

        ### C ###

        ca-certs = callPackage ../development/ocaml-modules/ca-certs { };

        ca-certs-nss = callPackage ../development/ocaml-modules/ca-certs-nss { };

        cachet = callPackage ../development/ocaml-modules/cachet { };

        cachet-lwt = callPackage ../development/ocaml-modules/cachet/lwt.nix { };

        cairo2 = callPackage ../development/ocaml-modules/cairo2 { };

        calendar = callPackage ../development/ocaml-modules/calendar { };

        callipyge = callPackage ../development/ocaml-modules/callipyge { };

        camlgpc = callPackage ../development/ocaml-modules/camlgpc { };

        camlidl = callPackage ../development/tools/ocaml/camlidl { };

        camlimages = callPackage ../development/ocaml-modules/camlimages { };

        camlp-streams = callPackage ../development/ocaml-modules/camlp-streams { };

        camlp4 =
          if lib.versionOlder "4.02" ocaml.version then
            callPackage ../development/tools/ocaml/camlp4 { }
          else
            null;

        camlp5 = callPackage ../development/tools/ocaml/camlp5 { };

        # Compatibility alias
        camlp5_strict = camlp5;

        camlpdf = callPackage ../development/ocaml-modules/camlpdf { };

        camlzip = callPackage ../development/ocaml-modules/camlzip { };

        camomile =
          if lib.versionOlder "4.02" ocaml.version then
            callPackage ../development/ocaml-modules/camomile { }
          else
            callPackage ../development/ocaml-modules/camomile/0.8.5.nix { };

        capnp = callPackage ../development/ocaml-modules/capnp { };

        caqti = callPackage ../development/ocaml-modules/caqti { };

        caqti-async = callPackage ../development/ocaml-modules/caqti/async.nix { };

        caqti-driver-mariadb = callPackage ../development/ocaml-modules/caqti/driver-mariadb.nix { };

        caqti-driver-postgresql = callPackage ../development/ocaml-modules/caqti/driver-postgresql.nix { };

        caqti-driver-sqlite3 = callPackage ../development/ocaml-modules/caqti/driver-sqlite3.nix { };

        caqti-dynload = callPackage ../development/ocaml-modules/caqti/dynload.nix { };

        caqti-eio = callPackage ../development/ocaml-modules/caqti/eio.nix { };

        caqti-lwt = callPackage ../development/ocaml-modules/caqti/lwt.nix { };

        caqti-type-calendar = callPackage ../development/ocaml-modules/caqti/type-calendar.nix { };

        carton = callPackage ../development/ocaml-modules/carton { };

        carton-git = callPackage ../development/ocaml-modules/carton/git.nix { };

        carton-lwt = callPackage ../development/ocaml-modules/carton/lwt.nix {
          git-binary = pkgs.git;
        };

        cbor = callPackage ../development/ocaml-modules/cbor { };

        cfstream = callPackage ../development/ocaml-modules/cfstream { };

        checkseum = callPackage ../development/ocaml-modules/checkseum { };

        chrome-trace = callPackage ../development/ocaml-modules/chrome-trace { };

        cil = callPackage ../development/ocaml-modules/cil { };

        clap = callPackage ../development/ocaml-modules/clap { };

        class_group_vdf = callPackage ../development/ocaml-modules/class_group_vdf { };

        cmarkit = callPackage ../development/ocaml-modules/cmarkit { };

        # The 1.1.0 release broke a lot of packages and is not compatible with
        # OCaml < 4.08.
        cmdliner = if lib.versionAtLeast ocaml.version "4.08" then cmdliner_1_1 else cmdliner_1_0;

        cmdliner_1_0 = callPackage ../development/ocaml-modules/cmdliner/1_0.nix { };

        cmdliner_1_1 = callPackage ../development/ocaml-modules/cmdliner/1_1.nix { };

        cohttp = callPackage ../development/ocaml-modules/cohttp { };

        cohttp-async = callPackage ../development/ocaml-modules/cohttp/async.nix { };

        cohttp-lwt = callPackage ../development/ocaml-modules/cohttp/lwt.nix { };

        cohttp-lwt-jsoo = callPackage ../development/ocaml-modules/cohttp/lwt-jsoo.nix { };

        cohttp-lwt-unix = callPackage ../development/ocaml-modules/cohttp/lwt-unix.nix { };

        cohttp-top = callPackage ../development/ocaml-modules/cohttp/top.nix { };

        coin = callPackage ../development/ocaml-modules/coin { };

        colombe = callPackage ../development/ocaml-modules/colombe { };

        color = callPackage ../development/ocaml-modules/color { };

        colors = callPackage ../development/ocaml-modules/colors { };

        conan = callPackage ../development/ocaml-modules/conan { };

        conan-cli = callPackage ../development/ocaml-modules/conan/cli.nix { };

        conan-database = callPackage ../development/ocaml-modules/conan/database.nix { };

        conan-lwt = callPackage ../development/ocaml-modules/conan/lwt.nix { };

        conan-unix = callPackage ../development/ocaml-modules/conan/unix.nix { };

        conduit = callPackage ../development/ocaml-modules/conduit { };

        conduit-async = callPackage ../development/ocaml-modules/conduit/async.nix { };

        conduit-lwt = callPackage ../development/ocaml-modules/conduit/lwt.nix { };

        conduit-lwt-unix = callPackage ../development/ocaml-modules/conduit/lwt-unix.nix { };

        conduit-mirage = callPackage ../development/ocaml-modules/conduit/mirage.nix { };

        config = callPackage ../development/ocaml-modules/config { };

        config-file = callPackage ../development/ocaml-modules/config-file { };

        containers = callPackage ../development/ocaml-modules/containers { };

        containers-data = callPackage ../development/ocaml-modules/containers/data.nix { };

        cooltt = callPackage ../development/ocaml-modules/cooltt { };

        cow = callPackage ../development/ocaml-modules/cow { };

        cpdf = callPackage ../development/ocaml-modules/cpdf { };

        cppo = callPackage ../development/tools/ocaml/cppo { };

        cppo_ocamlbuild = callPackage ../development/tools/ocaml/cppo/ocamlbuild.nix { };

        cpu = callPackage ../development/ocaml-modules/cpu { };

        cpuid = callPackage ../development/ocaml-modules/cpuid { };

        crowbar = callPackage ../development/ocaml-modules/crowbar { };

        crunch = callPackage ../development/tools/ocaml/crunch { };

        cry = callPackage ../development/ocaml-modules/cry { };

        cryptokit = callPackage ../development/ocaml-modules/cryptokit { };

        csexp = callPackage ../development/ocaml-modules/csexp { };

        cstruct = callPackage ../development/ocaml-modules/cstruct { };

        cstruct-async = callPackage ../development/ocaml-modules/cstruct/async.nix { };

        cstruct-lwt = callPackage ../development/ocaml-modules/cstruct/lwt.nix { };

        cstruct-sexp = callPackage ../development/ocaml-modules/cstruct/sexp.nix { };

        cstruct-unix = callPackage ../development/ocaml-modules/cstruct/unix.nix { };

        csv = callPackage ../development/ocaml-modules/csv { };

        csv-lwt = callPackage ../development/ocaml-modules/csv/lwt.nix { };

        ctypes = callPackage ../development/ocaml-modules/ctypes { };

        ctypes-foreign = callPackage ../development/ocaml-modules/ctypes/foreign.nix { };

        cudf = callPackage ../development/ocaml-modules/cudf { };

        curly = callPackage ../development/ocaml-modules/curly {
          inherit (pkgs) curl;
        };

        curses = callPackage ../development/ocaml-modules/curses { };

        ### D ###

        dap = callPackage ../development/ocaml-modules/dap { };

        data-encoding = callPackage ../development/ocaml-modules/data-encoding { };

        dates_calc = callPackage ../development/ocaml-modules/dates_calc { };

        dbf = callPackage ../development/ocaml-modules/dbf { };

        decoders = callPackage ../development/ocaml-modules/decoders { };

        decoders-bencode = callPackage ../development/ocaml-modules/decoders-bencode { };

        decoders-cbor = callPackage ../development/ocaml-modules/decoders-cbor { };

        decoders-ezjsonm = callPackage ../development/ocaml-modules/decoders-ezjsonm { };

        decoders-ezxmlm = callPackage ../development/ocaml-modules/decoders-ezxmlm { };

        decoders-jsonaf = callPackage ../development/ocaml-modules/decoders-jsonaf { };

        decoders-jsonm = callPackage ../development/ocaml-modules/decoders-jsonm { };

        decoders-msgpck = callPackage ../development/ocaml-modules/decoders-msgpck { };

        decoders-sexplib = callPackage ../development/ocaml-modules/decoders-sexplib { };

        decoders-yojson = callPackage ../development/ocaml-modules/decoders-yojson { };

        decompress = callPackage ../development/ocaml-modules/decompress { };

        dedukti = callPackage ../development/ocaml-modules/dedukti { };

        diet = callPackage ../development/ocaml-modules/diet { };

        digestif = callPackage ../development/ocaml-modules/digestif { };

        directories = callPackage ../development/ocaml-modules/directories { };

        dispatch = callPackage ../development/ocaml-modules/dispatch { };

        dns = callPackage ../development/ocaml-modules/dns { };

        dns-certify = callPackage ../development/ocaml-modules/dns/certify.nix { };

        dns-cli = callPackage ../development/ocaml-modules/dns/cli.nix { };

        dns-client = callPackage ../development/ocaml-modules/dns/client.nix { };

        dns-client-lwt = callPackage ../development/ocaml-modules/dns/client-lwt.nix { };

        dns-client-mirage = callPackage ../development/ocaml-modules/dns/client-mirage.nix { };

        dns-mirage = callPackage ../development/ocaml-modules/dns/mirage.nix { };

        dns-resolver = callPackage ../development/ocaml-modules/dns/resolver.nix { };

        dns-server = callPackage ../development/ocaml-modules/dns/server.nix { };

        dns-stub = callPackage ../development/ocaml-modules/dns/stub.nix { };

        dns-tsig = callPackage ../development/ocaml-modules/dns/tsig.nix { };

        dnssec = callPackage ../development/ocaml-modules/dns/dnssec.nix { };

        dockerfile = callPackage ../development/ocaml-modules/dockerfile { };

        dolmen = callPackage ../development/ocaml-modules/dolmen { };

        dolmen_loop = callPackage ../development/ocaml-modules/dolmen/loop.nix { };

        dolmen_lsp = callPackage ../development/ocaml-modules/dolmen/lsp.nix { };

        dolmen_model = callPackage ../development/ocaml-modules/dolmen/model.nix { };

        dolmen_type = callPackage ../development/ocaml-modules/dolmen/type.nix { };

        dolog = callPackage ../development/ocaml-modules/dolog { };

        domain-local-await = callPackage ../development/ocaml-modules/domain-local-await { };

        domain-local-timeout = callPackage ../development/ocaml-modules/domain-local-timeout { };

        domain-name = callPackage ../development/ocaml-modules/domain-name { };

        domain_shims = callPackage ../development/ocaml-modules/domain_shims { };

        domainslib = callPackage ../development/ocaml-modules/domainslib { };

        dose3 = callPackage ../development/ocaml-modules/dose3 { };

        dot-merlin-reader = callPackage ../development/tools/ocaml/merlin/dot-merlin-reader.nix { };

        dream = callPackage ../development/ocaml-modules/dream { };

        dream-html = callPackage ../development/ocaml-modules/dream-html { };

        dream-httpaf = callPackage ../development/ocaml-modules/dream/httpaf.nix { };

        dream-pure = callPackage ../development/ocaml-modules/dream/pure.nix { };

        dscheck = callPackage ../development/ocaml-modules/dscheck { };

        dssi = callPackage ../development/ocaml-modules/dssi { };

        dtoa = callPackage ../development/ocaml-modules/dtoa { };

        dtools = callPackage ../development/ocaml-modules/dtools { };

        duff = callPackage ../development/ocaml-modules/duff { };

        dum = callPackage ../development/ocaml-modules/dum { };

        dune_2 = callPackage ../development/tools/ocaml/dune/2.nix { };

        dune_3 = callPackage ../development/tools/ocaml/dune/3.nix { };

        dune-action-plugin = callPackage ../development/ocaml-modules/dune-action-plugin { };

        dune-build-info = callPackage ../development/ocaml-modules/dune-build-info { };

        dune-configurator = callPackage ../development/ocaml-modules/dune-configurator { };

        dune-glob = callPackage ../development/ocaml-modules/dune-glob { };

        dune-private-libs = callPackage ../development/ocaml-modules/dune-private-libs { };

        dune-release = callPackage ../development/tools/ocaml/dune-release {
          inherit (pkgs)
            opam
            gitMinimal
            mercurial
            coreutils
            gnutar
            bzip2
            ;
        };

        dune-rpc = callPackage ../development/ocaml-modules/dune-rpc { };

        dune-site = callPackage ../development/ocaml-modules/dune-site { };

        duppy = callPackage ../development/ocaml-modules/duppy { };

        duration = callPackage ../development/ocaml-modules/duration { };

        dyn = callPackage ../development/ocaml-modules/dyn { };

        dypgen = callPackage ../development/ocaml-modules/dypgen { };

        ### E ###

        earley = callPackage ../development/ocaml-modules/earley { };

        earlybird = callPackage ../development/ocaml-modules/earlybird { };

        easy-format = callPackage ../development/ocaml-modules/easy-format { };

        eigen = callPackage ../development/ocaml-modules/eigen { };

        eio = callPackage ../development/ocaml-modules/eio { };
        eio_linux = callPackage ../development/ocaml-modules/eio/linux.nix { };
        eio_main = callPackage ../development/ocaml-modules/eio/main.nix { };
        eio_posix = callPackage ../development/ocaml-modules/eio/posix.nix { };

        eio-ssl = callPackage ../development/ocaml-modules/eio-ssl { };

        either = callPackage ../development/ocaml-modules/either { };

        elina = callPackage ../development/ocaml-modules/elina {
          stdenv = pkgs.gcc13Stdenv;
        };

        eliom =
          let
            js_of_ocaml-compiler = self.js_of_ocaml-compiler.override { version = "5.9.1"; };
            js_of_ocaml = self.js_of_ocaml.override { inherit js_of_ocaml-compiler; };
          in
          callPackage ../development/ocaml-modules/eliom rec {
            js_of_ocaml-ppx = self.js_of_ocaml-ppx.override { inherit js_of_ocaml; };
            js_of_ocaml-ppx_deriving_json = self.js_of_ocaml-ppx_deriving_json.override {
              inherit js_of_ocaml;
            };
            js_of_ocaml-lwt = self.js_of_ocaml-lwt.override { inherit js_of_ocaml js_of_ocaml-ppx; };
            js_of_ocaml-tyxml = self.js_of_ocaml-tyxml.override { inherit js_of_ocaml js_of_ocaml-ppx; };
          };

        elpi = callPackage ../development/ocaml-modules/elpi (
          let
            ppx_deriving_ =
              cap:
              ppx_deriving.override {
                ppxlib = ppxlib.override {
                  version = if lib.versionAtLeast ppxlib.version cap then cap else ppxlib.version;
                };
              };
          in
          {
            ppx_deriving_0_15 = ppx_deriving_ "0.15";
            ppx_deriving_0_33 = ppx_deriving_ "0.33.0";
          }
        );

        emile = callPackage ../development/ocaml-modules/emile { };

        encore = callPackage ../development/ocaml-modules/encore { };

        eqaf = callPackage ../development/ocaml-modules/eqaf { };

        eqaf-cstruct = callPackage ../development/ocaml-modules/eqaf/cstruct.nix { };

        erm_xml = callPackage ../development/ocaml-modules/erm_xml { };

        erm_xmpp = callPackage ../development/ocaml-modules/erm_xmpp { };

        ethernet = callPackage ../development/ocaml-modules/ethernet { };

        extlib = extlib-1-7-9;

        extlib-1-7-9 = callPackage ../development/ocaml-modules/extlib { };

        extlib-1-7-7 = callPackage ../development/ocaml-modules/extlib/1.7.7.nix { };

        ezjsonm = callPackage ../development/ocaml-modules/ezjsonm { };

        ezjsonm-encoding = callPackage ../development/ocaml-modules/ezjsonm-encoding { };

        ezxmlm = callPackage ../development/ocaml-modules/ezxmlm { };

        ### F ###

        faad = callPackage ../development/ocaml-modules/faad { };

        facile = callPackage ../development/ocaml-modules/facile { };

        faraday = callPackage ../development/ocaml-modules/faraday { };

        faraday-async = callPackage ../development/ocaml-modules/faraday/async.nix { };

        faraday-lwt = callPackage ../development/ocaml-modules/faraday/lwt.nix { };

        faraday-lwt-unix = callPackage ../development/ocaml-modules/faraday/lwt-unix.nix { };

        farfadet = callPackage ../development/ocaml-modules/farfadet { };

        farith = callPackage ../development/ocaml-modules/farith { };

        fdkaac = callPackage ../development/ocaml-modules/fdkaac { };

        ff = callPackage ../development/ocaml-modules/ff { };
        ff-pbt = callPackage ../development/ocaml-modules/ff/pbt.nix { };
        ff-sig = callPackage ../development/ocaml-modules/ff/sig.nix { };

        ffmpeg = callPackage ../development/ocaml-modules/ffmpeg { };
        ffmpeg-av = callPackage ../development/ocaml-modules/ffmpeg/ffmpeg-av.nix {
          ffmpeg = pkgs.ffmpeg_6;
        };
        ffmpeg-avcodec = callPackage ../development/ocaml-modules/ffmpeg/ffmpeg-avcodec.nix {
          ffmpeg = pkgs.ffmpeg_6;
        };
        ffmpeg-avdevice = callPackage ../development/ocaml-modules/ffmpeg/ffmpeg-avdevice.nix {
          ffmpeg = pkgs.ffmpeg_6;
        };
        ffmpeg-avfilter = callPackage ../development/ocaml-modules/ffmpeg/ffmpeg-avfilter.nix {
          ffmpeg = pkgs.ffmpeg_6;
        };
        ffmpeg-avutil = callPackage ../development/ocaml-modules/ffmpeg/ffmpeg-avutil.nix {
          ffmpeg = pkgs.ffmpeg_6;
        };
        ffmpeg-swresample = callPackage ../development/ocaml-modules/ffmpeg/ffmpeg-swresample.nix {
          ffmpeg = pkgs.ffmpeg_6;
        };
        ffmpeg-swscale = callPackage ../development/ocaml-modules/ffmpeg/ffmpeg-swscale.nix {
          ffmpeg = pkgs.ffmpeg_6;
        };

        fiber = callPackage ../development/ocaml-modules/fiber { };

        fileutils = callPackage ../development/ocaml-modules/fileutils { };

        findlib = callPackage ../development/tools/ocaml/findlib { };

        fix = callPackage ../development/ocaml-modules/fix { };

        flac = callPackage ../development/ocaml-modules/flac {
          inherit (pkgs) flac;
        };

        flex = callPackage ../development/ocaml-modules/flex { };

        fmt = callPackage ../development/ocaml-modules/fmt { };

        fontconfig = callPackage ../development/ocaml-modules/fontconfig {
          inherit (pkgs) fontconfig;
        };

        fpath = callPackage ../development/ocaml-modules/fpath { };

        frei0r = callPackage ../development/ocaml-modules/frei0r {
          inherit (pkgs) frei0r;
        };

        frontc = callPackage ../development/ocaml-modules/frontc { };

        functory = callPackage ../development/ocaml-modules/functory { };

        ### G ###

        gapi-ocaml = callPackage ../development/ocaml-modules/gapi-ocaml { };

        gd = callPackage ../development/ocaml-modules/gd { inherit (pkgs) gd; };

        gen = callPackage ../development/ocaml-modules/gen { };

        gen_js_api = callPackage ../development/ocaml-modules/gen_js_api { };

        gendarme = callPackage ../development/ocaml-modules/gendarme { };

        genspio = callPackage ../development/ocaml-modules/genspio { };

        get-activity = callPackage ../development/ocaml-modules/get-activity { };

        get-activity-lib = callPackage ../development/ocaml-modules/get-activity/lib.nix { };

        getopt = callPackage ../development/ocaml-modules/getopt { };

        gettext-camomile = callPackage ../development/ocaml-modules/ocaml-gettext/camomile.nix { };

        gettext-stub = callPackage ../development/ocaml-modules/ocaml-gettext/stub.nix { };

        gg = callPackage ../development/ocaml-modules/gg { };

        git = callPackage ../development/ocaml-modules/git {
          git-binary = pkgs.git;
        };

        git-mirage = callPackage ../development/ocaml-modules/git/mirage.nix { };

        git-paf = callPackage ../development/ocaml-modules/git/paf.nix { };

        git-unix = callPackage ../development/ocaml-modules/git/unix.nix {
          git-binary = pkgs.git;
        };

        github = callPackage ../development/ocaml-modules/github { };
        github-data = callPackage ../development/ocaml-modules/github/data.nix { };
        github-jsoo = callPackage ../development/ocaml-modules/github/jsoo.nix { };
        github-unix = callPackage ../development/ocaml-modules/github/unix.nix { };

        gitlab = callPackage ../development/ocaml-modules/gitlab { };
        gitlab-jsoo = callPackage ../development/ocaml-modules/gitlab/jsoo.nix { };
        gitlab-unix = callPackage ../development/ocaml-modules/gitlab/unix.nix { };

        gluon = callPackage ../development/ocaml-modules/gluon { };

        gluten = callPackage ../development/ocaml-modules/gluten { };
        gluten-async = callPackage ../development/ocaml-modules/gluten/async.nix { };
        gluten-eio = callPackage ../development/ocaml-modules/gluten/eio.nix { };
        gluten-lwt = callPackage ../development/ocaml-modules/gluten/lwt.nix { };
        gluten-lwt-unix = callPackage ../development/ocaml-modules/gluten/lwt-unix.nix { };
        gluten-mirage = callPackage ../development/ocaml-modules/gluten/mirage.nix { };

        gmap = callPackage ../development/ocaml-modules/gmap { };

        gnuplot = callPackage ../development/ocaml-modules/gnuplot {
          inherit (pkgs) gnuplot;
        };

        graphics =
          if lib.versionOlder "4.09" ocaml.version then
            callPackage ../development/ocaml-modules/graphics { }
          else
            null;

        graphql = callPackage ../development/ocaml-modules/graphql { };

        graphql-cohttp = callPackage ../development/ocaml-modules/graphql/cohttp.nix { };

        graphql-lwt = callPackage ../development/ocaml-modules/graphql/lwt.nix { };

        graphql_parser = callPackage ../development/ocaml-modules/graphql/parser.nix { };

        graphql_ppx = callPackage ../development/ocaml-modules/graphql_ppx { };

        gsl = callPackage ../development/ocaml-modules/gsl {
          inherit (pkgs) gsl;
        };

        gstreamer = callPackage ../development/ocaml-modules/gstreamer { };

        ### H ###

        h1 = callPackage ../development/ocaml-modules/h1 { };

        h2 = callPackage ../development/ocaml-modules/h2 { };

        h2-eio = callPackage ../development/ocaml-modules/h2/eio.nix { };

        h2-lwt = callPackage ../development/ocaml-modules/h2/lwt.nix { };

        h2-lwt-unix = callPackage ../development/ocaml-modules/h2/lwt-unix.nix { };

        hack_parallel = callPackage ../development/ocaml-modules/hack_parallel { };

        hacl-star = callPackage ../development/ocaml-modules/hacl-star { };
        hacl-star-raw = callPackage ../development/ocaml-modules/hacl-star/raw.nix { };

        happy-eyeballs = callPackage ../development/ocaml-modules/happy-eyeballs { };

        happy-eyeballs-lwt = callPackage ../development/ocaml-modules/happy-eyeballs/lwt.nix { };

        happy-eyeballs-mirage = callPackage ../development/ocaml-modules/happy-eyeballs/mirage.nix { };

        hashcons = callPackage ../development/ocaml-modules/hashcons { };

        hc = callPackage ../development/ocaml-modules/hc { };

        hex = callPackage ../development/ocaml-modules/hex { };

        hidapi = callPackage ../development/ocaml-modules/hidapi { };

        higlo = callPackage ../development/ocaml-modules/higlo { };

        hkdf = callPackage ../development/ocaml-modules/hkdf { };

        hmap = callPackage ../development/ocaml-modules/hmap { };

        hpack = callPackage ../development/ocaml-modules/hpack { };

        http-mirage-client = callPackage ../development/ocaml-modules/http-mirage-client { };

        httpaf = callPackage ../development/ocaml-modules/httpaf { };

        httpaf-lwt-unix = callPackage ../development/ocaml-modules/httpaf/lwt-unix.nix { };

        httpun = callPackage ../development/ocaml-modules/httpun { };

        httpun-eio = callPackage ../development/ocaml-modules/httpun/eio.nix { };

        httpun-lwt = callPackage ../development/ocaml-modules/httpun/lwt.nix { };

        httpun-lwt-unix = callPackage ../development/ocaml-modules/httpun/lwt-unix.nix { };

        httpun-types = callPackage ../development/ocaml-modules/httpun/types.nix { };

        httpun-ws = callPackage ../development/ocaml-modules/httpun-ws { };

        httpun-ws-lwt = callPackage ../development/ocaml-modules/httpun-ws/lwt.nix { };
        hxd = callPackage ../development/ocaml-modules/hxd { };

        ### I ###

        imagelib = callPackage ../development/ocaml-modules/imagelib { };

        index = callPackage ../development/ocaml-modules/index { };

        inifiles = callPackage ../development/ocaml-modules/inifiles { };

        inotify = callPackage ../development/ocaml-modules/inotify { };

        integers = callPackage ../development/ocaml-modules/integers { };

        integers_stubs_js = callPackage ../development/ocaml-modules/integers_stubs_js { };

        iomux = callPackage ../development/ocaml-modules/iomux { };

        io-page = callPackage ../development/ocaml-modules/io-page { };

        ipaddr = callPackage ../development/ocaml-modules/ipaddr { };

        ipaddr-cstruct = callPackage ../development/ocaml-modules/ipaddr/cstruct.nix { };

        ipaddr-sexp = callPackage ../development/ocaml-modules/ipaddr/sexp.nix { };

        iri = callPackage ../development/ocaml-modules/iri { };

        irmin = callPackage ../development/ocaml-modules/irmin { };

        irmin-chunk = callPackage ../development/ocaml-modules/irmin/chunk.nix { };

        irmin-containers = callPackage ../development/ocaml-modules/irmin/containers.nix { };

        irmin-fs = callPackage ../development/ocaml-modules/irmin/fs.nix { };

        irmin-git = callPackage ../development/ocaml-modules/irmin/git.nix { };

        irmin-graphql = callPackage ../development/ocaml-modules/irmin/graphql.nix { };

        irmin-mirage = callPackage ../development/ocaml-modules/irmin/mirage.nix { };

        irmin-mirage-git = callPackage ../development/ocaml-modules/irmin/mirage-git.nix { };

        irmin-mirage-graphql = callPackage ../development/ocaml-modules/irmin/mirage-graphql.nix { };

        irmin-pack = callPackage ../development/ocaml-modules/irmin/pack.nix { };

        irmin-test = callPackage ../development/ocaml-modules/irmin/test.nix { };

        irmin-tezos = callPackage ../development/ocaml-modules/irmin/tezos.nix { };

        irmin-watcher = callPackage ../development/ocaml-modules/irmin-watcher { };

        iso8601 = callPackage ../development/ocaml-modules/iso8601 { };

        iter = callPackage ../development/ocaml-modules/iter { };

        ### J ###

        # Jane Street
        janePackage =
          if lib.versionOlder "5.1" ocaml.version then
            callPackage ../development/ocaml-modules/janestreet/janePackage_0_17.nix { }
          else if lib.versionOlder "4.13.1" ocaml.version then
            callPackage ../development/ocaml-modules/janestreet/janePackage_0_16.nix { }
          else if lib.versionOlder "4.10.2" ocaml.version then
            callPackage ../development/ocaml-modules/janestreet/janePackage_0_15.nix { }
          else if lib.versionOlder "4.08" ocaml.version then
            callPackage ../development/ocaml-modules/janestreet/janePackage_0_14.nix { }
          else if lib.versionOlder "4.07" ocaml.version then
            callPackage ../development/ocaml-modules/janestreet/janePackage_0_12.nix { }
          else
            null;

        janeStreet = lib.recurseIntoAttrs (
          if lib.versionOlder "5.1" ocaml.version then
            import ../development/ocaml-modules/janestreet/0.17.nix {
              inherit self;
              inherit (pkgs)
                bash
                fetchpatch
                fzf
                lib
                openssl
                zstd
                ;
            }
          else if lib.versionOlder "4.13.1" ocaml.version then
            import ../development/ocaml-modules/janestreet/0.16.nix {
              inherit self;
              inherit (pkgs)
                bash
                fetchpatch
                fzf
                lib
                openssl
                zstd
                krb5
                ;
            }
          else if lib.versionOlder "4.10.2" ocaml.version then
            import ../development/ocaml-modules/janestreet/0.15.nix {
              inherit self ocaml;
              inherit (pkgs)
                bash
                fetchpatch
                fzf
                lib
                openssl
                zstd
                ;
            }
          else if lib.versionOlder "4.08" ocaml.version then
            import ../development/ocaml-modules/janestreet/0.14.nix {
              inherit self;
              inherit (pkgs)
                fetchpatch
                lib
                openssl
                zstd
                ;
            }
          else if lib.versionOlder "4.07" ocaml.version then
            import ../development/ocaml-modules/janestreet/0.12.nix {
              self = self // {
                ppxlib = ppxlib.override { version = "0.8.1"; };
              };
              inherit (pkgs) openssl;
            }
          else
            import ../development/ocaml-modules/janestreet {
            }
        );

        javalib = callPackage ../development/ocaml-modules/javalib { };

        jingoo = callPackage ../development/ocaml-modules/jingoo { };

        jose = callPackage ../development/ocaml-modules/jose { };

        js_of_ocaml = callPackage ../development/tools/ocaml/js_of_ocaml { };

        js_of_ocaml-compiler = callPackage ../development/tools/ocaml/js_of_ocaml/compiler.nix { };

        js_of_ocaml-lwt = callPackage ../development/tools/ocaml/js_of_ocaml/lwt.nix { };

        js_of_ocaml-ocamlbuild = callPackage ../development/tools/ocaml/js_of_ocaml/ocamlbuild.nix { };

        js_of_ocaml-ppx = callPackage ../development/tools/ocaml/js_of_ocaml/ppx.nix { };

        js_of_ocaml-ppx_deriving_json =
          callPackage ../development/tools/ocaml/js_of_ocaml/ppx_deriving_json.nix
            { };

        js_of_ocaml-toplevel = callPackage ../development/tools/ocaml/js_of_ocaml/toplevel.nix { };

        js_of_ocaml-tyxml = callPackage ../development/tools/ocaml/js_of_ocaml/tyxml.nix { };

        json-data-encoding = callPackage ../development/ocaml-modules/json-data-encoding { };

        json-data-encoding-bson = callPackage ../development/ocaml-modules/json-data-encoding/bson.nix { };

        jsonm = callPackage ../development/ocaml-modules/jsonm { };

        jsont = callPackage ../development/ocaml-modules/jsont { };

        jsonrpc = callPackage ../development/ocaml-modules/ocaml-lsp/jsonrpc.nix { };

        junit = callPackage ../development/ocaml-modules/junit { };
        junit_alcotest = callPackage ../development/ocaml-modules/junit/alcotest.nix { };
        junit_ounit = callPackage ../development/ocaml-modules/junit/ounit.nix { };

        jwto = callPackage ../development/ocaml-modules/jwto { };

        ### K ###

        kafka = callPackage ../development/ocaml-modules/kafka { };

        kafka_lwt = callPackage ../development/ocaml-modules/kafka/lwt.nix { };

        kcas = callPackage ../development/ocaml-modules/kcas { };

        kdf = callPackage ../development/ocaml-modules/kdf { };

        kdl = callPackage ../development/ocaml-modules/kdl { };

        ke = callPackage ../development/ocaml-modules/ke { };

        kicadsch = callPackage ../development/ocaml-modules/kicadsch { };

        kqueue = callPackage ../development/ocaml-modules/kqueue { };

        ### L ###

        lablgl = callPackage ../development/ocaml-modules/lablgl { };

        lablgtk = callPackage ../development/ocaml-modules/lablgtk {
          inherit (pkgs.gnome2) libgnomecanvas gtksourceview;
        };

        lablgtk-extras =
          if lib.versionOlder "4.02" ocaml.version then
            callPackage ../development/ocaml-modules/lablgtk-extras { }
          else
            callPackage ../development/ocaml-modules/lablgtk-extras/1.4.nix { };

        lablgtk3 = callPackage ../development/ocaml-modules/lablgtk3 { };

        lablgtk3-gtkspell3 = callPackage ../development/ocaml-modules/lablgtk3/gtkspell3.nix { };

        lablgtk3-rsvg2 = callPackage ../development/ocaml-modules/lablgtk3/rsvg2.nix { };

        lablgtk3-sourceview3 = callPackage ../development/ocaml-modules/lablgtk3/sourceview3.nix { };

        labltk = callPackage ../development/ocaml-modules/labltk { };

        lacaml = callPackage ../development/ocaml-modules/lacaml { };

        ladspa = callPackage ../development/ocaml-modules/ladspa { };

        lambda-term = callPackage ../development/ocaml-modules/lambda-term { };

        lambdapi = callPackage ../development/ocaml-modules/lambdapi {
          why3 = pkgs.why3.override { ocamlPackages = self; };
        };

        lambdasoup = callPackage ../development/ocaml-modules/lambdasoup { };

        lame = callPackage ../development/ocaml-modules/lame {
          inherit (pkgs) lame;
        };

        landmarks = callPackage ../development/ocaml-modules/landmarks { };

        landmarks-ppx = callPackage ../development/ocaml-modules/landmarks-ppx { };

        lastfm = callPackage ../development/ocaml-modules/lastfm { };

        lem = callPackage ../development/ocaml-modules/lem { };

        lens = callPackage ../development/ocaml-modules/lens { };

        letsencrypt = callPackage ../development/ocaml-modules/letsencrypt { };

        letsencrypt-app = callPackage ../development/ocaml-modules/letsencrypt/app.nix { };

        letsencrypt-dns = callPackage ../development/ocaml-modules/letsencrypt/dns.nix { };

        letsencrypt-mirage = callPackage ../development/ocaml-modules/letsencrypt/mirage.nix { };

        letters = callPackage ../development/ocaml-modules/letters { };

        libc = callPackage ../development/ocaml-modules/libc { };

        lilv = callPackage ../development/ocaml-modules/lilv {
          inherit (pkgs) lilv;
        };

        linenoise = callPackage ../development/ocaml-modules/linenoise { };

        linksem = callPackage ../development/ocaml-modules/linksem { };

        linol = callPackage ../development/ocaml-modules/linol { };

        linol-eio = callPackage ../development/ocaml-modules/linol/eio.nix { };

        linol-lwt = callPackage ../development/ocaml-modules/linol/lwt.nix { };

        llvm = callPackage ../development/ocaml-modules/llvm {
          libllvm = pkgs.llvmPackages.libllvm;
        };

        lo = callPackage ../development/ocaml-modules/lo { };

        logs = callPackage ../development/ocaml-modules/logs { };

        logs-syslog = callPackage ../development/ocaml-modules/logs-syslog { };

        lru = callPackage ../development/ocaml-modules/lru { };

        lsp = callPackage ../development/ocaml-modules/ocaml-lsp/lsp.nix { };

        lua-ml = callPackage ../development/ocaml-modules/lua-ml { };

        lun = callPackage ../development/ocaml-modules/lun { };

        lustre-v6 = callPackage ../development/ocaml-modules/lustre-v6 { };

        lutils = callPackage ../development/ocaml-modules/lutils { };

        luv = callPackage ../development/ocaml-modules/luv {
          inherit (pkgs) file;
        };

        lwd = callPackage ../development/ocaml-modules/lwd { };

        lwt = callPackage ../development/ocaml-modules/lwt { };

        lwt-canceler = callPackage ../development/ocaml-modules/lwt-canceler { };

        lwt-dllist = callPackage ../development/ocaml-modules/lwt-dllist { };

        lwt_eio = callPackage ../development/ocaml-modules/lwt_eio { };

        lwt-exit = callPackage ../development/ocaml-modules/lwt-exit { };

        lwt_log = callPackage ../development/ocaml-modules/lwt_log { };

        lwt_ppx = callPackage ../development/ocaml-modules/lwt/ppx.nix { };

        lwt_react = callPackage ../development/ocaml-modules/lwt_react { };

        lwt_ssl = callPackage ../development/ocaml-modules/lwt_ssl { };

        lwt-watcher = callPackage ../development/ocaml-modules/lwt-watcher { };

        ### M ###

        macaddr = callPackage ../development/ocaml-modules/macaddr { };

        macaddr-cstruct = callPackage ../development/ocaml-modules/macaddr/cstruct.nix { };

        macaddr-sexp = callPackage ../development/ocaml-modules/macaddr/sexp.nix { };

        mad = callPackage ../development/ocaml-modules/mad { };

        magic = callPackage ../development/ocaml-modules/magic { };

        magic-mime = callPackage ../development/ocaml-modules/magic-mime { };

        magic-trace = callPackage ../development/ocaml-modules/magic-trace { };

        mariadb = callPackage ../development/ocaml-modules/mariadb {
          inherit (pkgs) mariadb;
        };

        markup = callPackage ../development/ocaml-modules/markup { };

        mccs = callPackage ../development/ocaml-modules/mccs { };

        mdx = callPackage ../development/ocaml-modules/mdx {
          logs = logs.override {
            jsooSupport = false;
            lwtSupport = false;
          };
        };

        mec = callPackage ../development/ocaml-modules/mec { };

        melange = callPackage ../development/tools/ocaml/melange { };

        melange-json = callPackage ../development/ocaml-modules/melange-json { };
        melange-json-native = callPackage ../development/ocaml-modules/melange-json/native.nix { };

        memprof-limits = callPackage ../development/ocaml-modules/memprof-limits { };

        memtrace = callPackage ../development/ocaml-modules/memtrace { };

        mem_usage = callPackage ../development/ocaml-modules/mem_usage { };

        menhir = callPackage ../development/ocaml-modules/menhir { };

        menhirLib = callPackage ../development/ocaml-modules/menhir/lib.nix { };

        menhirSdk = callPackage ../development/ocaml-modules/menhir/sdk.nix { };

        merlin =
          if lib.versionAtLeast ocaml.version "4.12" then
            callPackage ../development/tools/ocaml/merlin/4.x.nix { }
          else
            callPackage ../development/tools/ocaml/merlin { };

        merlin-extend = callPackage ../development/ocaml-modules/merlin-extend { };

        merlin-lib = callPackage ../development/tools/ocaml/merlin/lib.nix { };

        metadata = callPackage ../development/ocaml-modules/metadata { };

        metrics = callPackage ../development/ocaml-modules/metrics { };

        metrics-influx = callPackage ../development/ocaml-modules/metrics/influx.nix { };

        metrics-lwt = callPackage ../development/ocaml-modules/metrics/lwt.nix { };

        metrics-rusage = callPackage ../development/ocaml-modules/metrics/rusage.nix { };

        metrics-unix = callPackage ../development/ocaml-modules/metrics/unix.nix {
          inherit (pkgs) gnuplot;
        };

        mew = callPackage ../development/ocaml-modules/mew { };

        mew_vi = callPackage ../development/ocaml-modules/mew_vi { };

        mezzo = callPackage ../development/compilers/mezzo { };

        middleware = callPackage ../development/ocaml-modules/middleware { };

        mimic = callPackage ../development/ocaml-modules/mimic { };

        mimic-happy-eyeballs = callPackage ../development/ocaml-modules/mimic/happy-eyeballs.nix { };

        minisat = callPackage ../development/ocaml-modules/minisat { };

        minttea = callPackage ../development/ocaml-modules/minttea { };

        miou = callPackage ../development/ocaml-modules/miou { };

        mirage = callPackage ../development/ocaml-modules/mirage { };

        mirage-block = callPackage ../development/ocaml-modules/mirage-block { };

        mirage-block-combinators =
          callPackage ../development/ocaml-modules/mirage-block/combinators.nix
            { };

        mirage-block-ramdisk = callPackage ../development/ocaml-modules/mirage-block-ramdisk { };

        mirage-block-unix = callPackage ../development/ocaml-modules/mirage-block-unix { };

        mirage-bootvar-unix = callPackage ../development/ocaml-modules/mirage-bootvar-unix { };

        mirage-bootvar-xen = callPackage ../development/ocaml-modules/mirage-bootvar-xen { };

        mirage-clock = callPackage ../development/ocaml-modules/mirage-clock { };

        mirage-clock-solo5 = callPackage ../development/ocaml-modules/mirage-clock/solo5.nix { };

        mirage-clock-unix = callPackage ../development/ocaml-modules/mirage-clock/unix.nix { };

        mirage-console = callPackage ../development/ocaml-modules/mirage-console { };

        mirage-crypto = callPackage ../development/ocaml-modules/mirage-crypto { };

        mirage-crypto-ec = callPackage ../development/ocaml-modules/mirage-crypto/ec.nix { };

        mirage-crypto-pk = callPackage ../development/ocaml-modules/mirage-crypto/pk.nix { };

        mirage-crypto-rng = callPackage ../development/ocaml-modules/mirage-crypto/rng.nix { };

        mirage-crypto-rng-mirage =
          callPackage ../development/ocaml-modules/mirage-crypto/rng-mirage.nix
            { };

        mirage-crypto-rng-miou-unix =
          callPackage ../development/ocaml-modules/mirage-crypto/rng-miou-unix.nix
            { };

        mirage-device = callPackage ../development/ocaml-modules/mirage-device { };

        mirage-flow = callPackage ../development/ocaml-modules/mirage-flow { };

        mirage-flow-combinators = callPackage ../development/ocaml-modules/mirage-flow/combinators.nix { };

        mirage-flow-unix = callPackage ../development/ocaml-modules/mirage-flow/unix.nix { };

        mirage-kv = callPackage ../development/ocaml-modules/mirage-kv { };

        mirage-logs = callPackage ../development/ocaml-modules/mirage-logs { };

        mirage-mtime = callPackage ../development/ocaml-modules/mirage-mtime { };

        mirage-nat = callPackage ../development/ocaml-modules/mirage-nat { };

        mirage-net = callPackage ../development/ocaml-modules/mirage-net { };

        mirage-net-xen = callPackage ../development/ocaml-modules/mirage-net-xen { };

        mirage-profile = callPackage ../development/ocaml-modules/mirage-profile { };

        mirage-protocols = callPackage ../development/ocaml-modules/mirage-protocols { };

        mirage-ptime = callPackage ../development/ocaml-modules/mirage-ptime { };

        mirage-random = callPackage ../development/ocaml-modules/mirage-random { };

        mirage-random-test = callPackage ../development/ocaml-modules/mirage-random-test { };

        mirage-runtime = callPackage ../development/ocaml-modules/mirage/runtime.nix { };

        mirage-sleep = callPackage ../development/ocaml-modules/mirage-sleep { };

        mirage-time = callPackage ../development/ocaml-modules/mirage-time { };

        mirage-time-unix = callPackage ../development/ocaml-modules/mirage-time/unix.nix { };

        mirage-unix = callPackage ../development/ocaml-modules/mirage-unix { };

        mirage-xen = callPackage ../development/ocaml-modules/mirage-xen { };

        mirage-vnetif = callPackage ../development/ocaml-modules/mirage-vnetif { };

        mlbdd = callPackage ../development/ocaml-modules/mlbdd { };

        mldoc = callPackage ../development/ocaml-modules/mldoc { };

        mlgmpidl = callPackage ../development/ocaml-modules/mlgmpidl { };

        mlx = callPackage ../development/ocaml-modules/mlx { };

        mm = callPackage ../development/ocaml-modules/mm { };

        mmap = callPackage ../development/ocaml-modules/mmap { };

        monolith = callPackage ../development/ocaml-modules/monolith { };

        mopsa = callPackage ../development/ocaml-modules/mopsa {
          inherit (pkgs.llvmPackages_19) clang libclang libllvm;
        };

        morbig = callPackage ../development/ocaml-modules/morbig { };

        mparser = callPackage ../development/ocaml-modules/mparser { };

        mparser-pcre = callPackage ../development/ocaml-modules/mparser/pcre.nix { };

        msgpck = callPackage ../development/ocaml-modules/msgpck { };

        mrmime = callPackage ../development/ocaml-modules/mrmime { };

        msat = callPackage ../development/ocaml-modules/msat { };

        mtime = callPackage ../development/ocaml-modules/mtime { };

        multicore-bench = callPackage ../development/ocaml-modules/multicore-bench { };

        multicore-magic = callPackage ../development/ocaml-modules/multicore-magic { };
        multicore-magic-dscheck = callPackage ../development/ocaml-modules/multicore-magic/dscheck.nix { };

        multipart_form = callPackage ../development/ocaml-modules/multipart_form { };

        multipart_form-eio = callPackage ../development/ocaml-modules/multipart_form/eio.nix { };

        multipart_form-lwt = callPackage ../development/ocaml-modules/multipart_form/lwt.nix { };

        multipart_form-miou = callPackage ../development/ocaml-modules/multipart_form/miou.nix { };

        multipart-form-data = callPackage ../development/ocaml-modules/multipart-form-data { };

        mustache = callPackage ../development/ocaml-modules/mustache { };

        ### N ###

        nbd = pkgs.libnbd.override {
          ocamlPackages = self;
          buildOcamlBindings = true;
        };

        netchannel = callPackage ../development/ocaml-modules/netchannel { };

        nice_parser = callPackage ../development/ocaml-modules/nice_parser { };

        ninja_utils = callPackage ../development/ocaml-modules/ninja_utils { };

        note = callPackage ../development/ocaml-modules/note { };

        nottui = callPackage ../development/ocaml-modules/lwd/nottui.nix { };

        nottui-lwt = callPackage ../development/ocaml-modules/lwd/nottui-lwt.nix { };

        nottui-pretty = callPackage ../development/ocaml-modules/lwd/nottui-pretty.nix { };

        nottui-unix = callPackage ../development/ocaml-modules/lwd/nottui-unix.nix { };

        notty = callPackage ../development/ocaml-modules/notty { };

        npy = callPackage ../development/ocaml-modules/npy {
          inherit (pkgs.python3Packages) numpy;
        };

        num =
          if lib.versionOlder "4.06" ocaml.version then
            callPackage ../development/ocaml-modules/num { }
          else
            null;

        ### O ###

        ocaml_cairo = callPackage ../development/ocaml-modules/ocaml-cairo { };

        ocaml_cryptgps = callPackage ../development/ocaml-modules/cryptgps { };

        ocaml_expat = callPackage ../development/ocaml-modules/expat { };

        ocaml-freestanding = callPackage ../development/ocaml-modules/ocaml-freestanding { };

        ocaml_gettext = callPackage ../development/ocaml-modules/ocaml-gettext { };

        ocaml_libvirt = callPackage ../development/ocaml-modules/ocaml-libvirt { };

        ocaml-lsp = callPackage ../development/ocaml-modules/ocaml-lsp { };

        ocaml-lua = callPackage ../development/ocaml-modules/ocaml-lua { };

        ocaml_lwt = lwt;

        ocaml-migrate-parsetree = ocaml-migrate-parsetree-1-8;

        ocaml-migrate-parsetree-1-8 =
          callPackage ../development/ocaml-modules/ocaml-migrate-parsetree/1.8.x.nix
            { };

        ocaml-migrate-parsetree-2 =
          callPackage ../development/ocaml-modules/ocaml-migrate-parsetree/2.x.nix
            { };

        ocaml-monadic = callPackage ../development/ocaml-modules/ocaml-monadic { };

        ocaml_mysql = callPackage ../development/ocaml-modules/mysql { };

        ocaml_oasis = callPackage ../development/tools/ocaml/oasis { };

        ocaml_pcre = callPackage ../development/ocaml-modules/pcre { };

        ocaml-print-intf = callPackage ../development/ocaml-modules/ocaml-print-intf { };

        ocaml-protoc = callPackage ../development/ocaml-modules/ocaml-protoc { };

        ocaml-protoc-plugin = callPackage ../development/ocaml-modules/ocaml-protoc-plugin { };

        ocaml-r = callPackage ../development/ocaml-modules/ocaml-r { };

        ocaml-recovery-parser = callPackage ../development/tools/ocaml/ocaml-recovery-parser { };

        ocaml-sat-solvers = callPackage ../development/ocaml-modules/ocaml-sat-solvers { };

        ocaml_sqlite3 = callPackage ../development/ocaml-modules/sqlite3 { };

        ocaml-syntax-shims = callPackage ../development/ocaml-modules/ocaml-syntax-shims { };

        ocaml-version = callPackage ../development/ocaml-modules/ocaml-version { };

        ocamlbuild =
          if lib.versionOlder "4.03" ocaml.version then
            callPackage ../development/tools/ocaml/ocamlbuild { }
          else
            null;

        ocamlc-loc = callPackage ../development/ocaml-modules/ocamlc-loc { };

        # Older versions of OCamlformat should be removed when their usage decrease
        # This script scraps Github looking for OCamlformat's options and versions usage:
        #  https://gist.github.com/Julow/110dc94308d6078225e0665e3eccd433
        ocamlformat_0_19_0 = ocamlformat.override { version = "0.19.0"; };
        ocamlformat_0_20_0 = ocamlformat.override { version = "0.20.0"; };
        ocamlformat_0_20_1 = ocamlformat.override { version = "0.20.1"; };
        ocamlformat_0_21_0 = ocamlformat.override { version = "0.21.0"; };
        ocamlformat_0_22_4 = ocamlformat.override { version = "0.22.4"; };
        ocamlformat_0_23_0 = ocamlformat.override { version = "0.23.0"; };
        ocamlformat_0_24_1 = ocamlformat.override { version = "0.24.1"; };
        ocamlformat_0_25_1 = ocamlformat.override { version = "0.25.1"; };
        ocamlformat_0_26_0 = ocamlformat.override { version = "0.26.0"; };
        ocamlformat_0_26_1 = ocamlformat.override { version = "0.26.1"; };
        ocamlformat_0_26_2 = ocamlformat.override { version = "0.26.2"; };
        ocamlformat_0_27_0 = ocamlformat.override { version = "0.27.0"; };
        ocamlformat_0_28_1 = ocamlformat.override { version = "0.28.1"; };

        ocamlformat = callPackage ../development/ocaml-modules/ocamlformat/ocamlformat.nix { };

        ocamlformat-lib = callPackage ../development/ocaml-modules/ocamlformat/ocamlformat-lib.nix { };

        ocamlformat-mlx = callPackage ../development/ocaml-modules/ocamlformat-mlx { };

        ocamlformat-mlx-lib = callPackage ../development/ocaml-modules/ocamlformat-mlx/lib.nix { };

        ocamlformat-rpc-lib =
          callPackage ../development/ocaml-modules/ocamlformat/ocamlformat-rpc-lib.nix
            { };

        ocamlfuse = callPackage ../development/ocaml-modules/ocamlfuse { };

        ocamlgraph = callPackage ../development/ocaml-modules/ocamlgraph { };
        ocamlgraph_gtk = callPackage ../development/ocaml-modules/ocamlgraph/gtk.nix { };

        ocamlify = callPackage ../development/tools/ocaml/ocamlify { };

        ocamline = callPackage ../development/ocaml-modules/ocamline { };

        ocamlmerlin-mlx = callPackage ../development/ocaml-modules/mlx/ocamlmerlin-mlx.nix { };

        ocamlmod = callPackage ../development/tools/ocaml/ocamlmod { };

        ocamlnet = callPackage ../development/ocaml-modules/ocamlnet { };

        ocamlscript = callPackage ../development/tools/ocaml/ocamlscript { };

        ocb = callPackage ../development/ocaml-modules/ocb { };

        ocb-stubblr = callPackage ../development/ocaml-modules/ocb-stubblr { };

        ocf = callPackage ../development/ocaml-modules/ocf { };

        ocf_ppx = callPackage ../development/ocaml-modules/ocf/ppx.nix { };

        ocolor = callPackage ../development/ocaml-modules/ocolor { };

        ocp-browser = callPackage ../development/tools/ocaml/ocp-browser { };

        ocp-build = callPackage ../development/tools/ocaml/ocp-build { };

        ocp-indent = callPackage ../development/tools/ocaml/ocp-indent { };

        ocp-index = callPackage ../development/tools/ocaml/ocp-index { };

        ocp-ocamlres = callPackage ../development/ocaml-modules/ocp-ocamlres { };

        ocplib-endian = callPackage ../development/ocaml-modules/ocplib-endian { };

        ocplib-simplex = callPackage ../development/ocaml-modules/ocplib-simplex { };

        ocsigen-ppx-rpc = callPackage ../development/ocaml-modules/ocsigen-ppx-rpc { };

        ocsigen_server = callPackage ../development/ocaml-modules/ocsigen-server { };

        ocsigen-start = callPackage ../development/ocaml-modules/ocsigen-start { };

        ocsigen-toolkit =
          let
            js_of_ocaml-compiler = self.js_of_ocaml-compiler.override { version = "5.9.1"; };
            js_of_ocaml = self.js_of_ocaml.override { inherit js_of_ocaml-compiler; };
          in
          callPackage ../development/ocaml-modules/ocsigen-toolkit {
            js_of_ocaml-ppx_deriving_json = self.js_of_ocaml-ppx_deriving_json.override {
              inherit js_of_ocaml;
            };
          };

        ocsipersist = callPackage ../development/ocaml-modules/ocsipersist { };

        ocsipersist-lib = callPackage ../development/ocaml-modules/ocsipersist/lib.nix { };

        ocsipersist-pgsql = callPackage ../development/ocaml-modules/ocsipersist/pgsql.nix { };

        ocsipersist-pgsql-config =
          callPackage ../development/ocaml-modules/ocsipersist/pgsql-config.nix
            { };

        ocsipersist-sqlite = callPackage ../development/ocaml-modules/ocsipersist/sqlite.nix { };

        ocsipersist-sqlite-config =
          callPackage ../development/ocaml-modules/ocsipersist/sqlite-config.nix
            { };

        octavius = callPackage ../development/ocaml-modules/octavius { };

        ocurl = callPackage ../development/ocaml-modules/ocurl { };

        odate = callPackage ../development/ocaml-modules/odate { };

        odds = callPackage ../development/ocaml-modules/odds { };

        odig = callPackage ../development/ocaml-modules/odig { };

        odoc = callPackage ../development/ocaml-modules/odoc { };

        odoc-parser = callPackage ../development/ocaml-modules/odoc-parser { };

        ogg = callPackage ../development/ocaml-modules/ogg { };

        ohex = callPackage ../development/ocaml-modules/ohex { };

        oidc = callPackage ../development/ocaml-modules/oidc { };

        ojs = callPackage ../development/ocaml-modules/gen_js_api/ojs.nix { };

        omd = callPackage ../development/ocaml-modules/omd { };

        opam-0install-cudf = callPackage ../development/ocaml-modules/opam-0install-cudf { };

        opam-core = callPackage ../development/ocaml-modules/opam-core {
          inherit (pkgs) opam;
        };

        opam-client = callPackage ../development/ocaml-modules/opam-client { };

        opam-file-format = callPackage ../development/ocaml-modules/opam-file-format { };

        opam-format = callPackage ../development/ocaml-modules/opam-format { };

        opam-repository = callPackage ../development/ocaml-modules/opam-repository { };

        opam-solver = callPackage ../development/ocaml-modules/opam-solver { };

        opam-state = callPackage ../development/ocaml-modules/opam-state { };

        opium = callPackage ../development/ocaml-modules/opium { };

        opti = callPackage ../development/ocaml-modules/opti { };

        optint = callPackage ../development/ocaml-modules/optint { };

        opus = callPackage ../development/ocaml-modules/opus { };

        ordering = callPackage ../development/ocaml-modules/ordering { };

        osdp = callPackage ../development/ocaml-modules/osdp { };

        oseq = callPackage ../development/ocaml-modules/oseq { };

        otfed = callPackage ../development/ocaml-modules/otfed { };

        otfm = callPackage ../development/ocaml-modules/otfm { };

        otoml = callPackage ../development/ocaml-modules/otoml { };

        otr = callPackage ../development/ocaml-modules/otr { };

        oui = callPackage ../development/ocaml-modules/oui { };

        ounit = callPackage ../development/ocaml-modules/ounit { };

        ounit2 = callPackage ../development/ocaml-modules/ounit2 { };

        owee = callPackage ../development/ocaml-modules/owee { };

        owl = callPackage ../development/ocaml-modules/owl { };

        owl-base = callPackage ../development/ocaml-modules/owl-base { };

        ### P ###

        paf = callPackage ../development/ocaml-modules/paf { };

        paf-cohttp = callPackage ../development/ocaml-modules/paf/cohttp.nix { };

        parany = callPackage ../development/ocaml-modules/parany { };

        parmap = callPackage ../development/ocaml-modules/parmap { };

        parse-argv = callPackage ../development/ocaml-modules/parse-argv { };

        patch = callPackage ../development/ocaml-modules/patch { };

        path_glob = callPackage ../development/ocaml-modules/path_glob { };

        patricia-tree = callPackage ../development/ocaml-modules/patricia-tree { };

        pbkdf = callPackage ../development/ocaml-modules/pbkdf { };

        pbrt = callPackage ../development/ocaml-modules/pbrt { };

        pcre2 = callPackage ../development/ocaml-modules/pcre2 {
          inherit (pkgs) pcre2;
        };

        pcap-format = callPackage ../development/ocaml-modules/pcap-format { };

        pecu = callPackage ../development/ocaml-modules/pecu { };

        pgocaml = callPackage ../development/ocaml-modules/pgocaml { };

        pgocaml_ppx = callPackage ../development/ocaml-modules/pgocaml/ppx.nix { };

        pgsolver = callPackage ../development/ocaml-modules/pgsolver { };

        phylogenetics = callPackage ../development/ocaml-modules/phylogenetics { };

        piaf = callPackage ../development/ocaml-modules/piaf { };

        piqi = callPackage ../development/ocaml-modules/piqi { };

        piqi-ocaml = callPackage ../development/ocaml-modules/piqi-ocaml { };

        plotkicadsch = callPackage ../development/ocaml-modules/plotkicadsch {
          inherit (pkgs) coreutils imagemagick;
        };

        poll = callPackage ../development/ocaml-modules/poll { };

        polynomial = callPackage ../development/ocaml-modules/polynomial { };

        portaudio = callPackage ../development/ocaml-modules/portaudio {
          inherit (pkgs) portaudio;
        };

        posix-base = callPackage ../development/ocaml-modules/posix/base.nix { };

        posix-math2 = callPackage ../development/ocaml-modules/posix/math2.nix { };

        posix-socket = callPackage ../development/ocaml-modules/posix/socket.nix { };

        posix-time2 = callPackage ../development/ocaml-modules/posix/time2.nix { };

        posix-types = callPackage ../development/ocaml-modules/posix/types.nix { };

        postgresql = callPackage ../development/ocaml-modules/postgresql {
          inherit (pkgs) libpq;
        };

        pp = callPackage ../development/ocaml-modules/pp { };

        pp_loc = callPackage ../development/ocaml-modules/pp_loc { };

        pprint = callPackage ../development/ocaml-modules/pprint { };

        ppx_bap = callPackage ../development/ocaml-modules/ppx_bap { };

        ppx_bitstring = callPackage ../development/ocaml-modules/bitstring/ppx.nix { };

        ppx_blob = callPackage ../development/ocaml-modules/ppx_blob { };

        ppx_cstruct = callPackage ../development/ocaml-modules/cstruct/ppx.nix { };

        ppx_cstubs = callPackage ../development/ocaml-modules/ppx_cstubs { };

        ppx_derivers = callPackage ../development/ocaml-modules/ppx_derivers { };

        ppx_deriving = callPackage ../development/ocaml-modules/ppx_deriving { };

        ppx_deriving_cmdliner = callPackage ../development/ocaml-modules/ppx_deriving_cmdliner { };

        ppx_deriving_protobuf = callPackage ../development/ocaml-modules/ppx_deriving_protobuf { };

        ppx_deriving_qcheck = callPackage ../development/ocaml-modules/qcheck/ppx_deriving_qcheck.nix { };

        ppx_deriving_rpc = callPackage ../development/ocaml-modules/ppx_deriving_rpc { };

        ppx_deriving_yaml = callPackage ../development/ocaml-modules/ppx_deriving_yaml {
          mdx = mdx.override { inherit logs; };
        };

        ppx_deriving_yojson = callPackage ../development/ocaml-modules/ppx_deriving_yojson { };

        ppx_gen_rec = callPackage ../development/ocaml-modules/ppx_gen_rec { };

        ppx_import = callPackage ../development/ocaml-modules/ppx_import { };

        ppx_irmin = callPackage ../development/ocaml-modules/irmin/ppx.nix { };

        ppx_lun = callPackage ../development/ocaml-modules/lun/ppx.nix { };

        ppx_monad = callPackage ../development/ocaml-modules/ppx_monad { };

        ppx_repr = callPackage ../development/ocaml-modules/repr/ppx.nix { };

        ppx_show = callPackage ../development/ocaml-modules/ppx_show { };

        ppx_tools =
          if lib.versionAtLeast ocaml.version "4.02" then
            callPackage ../development/ocaml-modules/ppx_tools { }
          else
            null;

        ppx_tools_versioned = callPackage ../development/ocaml-modules/ppx_tools_versioned { };

        ppx_yojson_conv = callPackage ../development/ocaml-modules/ppx_yojson_conv { };

        ppx_yojson_conv_lib = callPackage ../development/ocaml-modules/ppx_yojson_conv_lib { };

        ppxlib = callPackage ../development/ocaml-modules/ppxlib { };

        pratter = callPackage ../development/ocaml-modules/pratter { };

        prelude = callPackage ../development/ocaml-modules/prelude { };

        prettym = callPackage ../development/ocaml-modules/prettym { };

        printbox = callPackage ../development/ocaml-modules/printbox { };

        printbox-text = callPackage ../development/ocaml-modules/printbox/text.nix { };

        process = callPackage ../development/ocaml-modules/process { };

        processor = callPackage ../development/ocaml-modules/processor { };

        prometheus = callPackage ../development/ocaml-modules/prometheus { };

        progress = callPackage ../development/ocaml-modules/progress { };

        promise_jsoo = callPackage ../development/ocaml-modules/promise_jsoo { };

        psmt2-frontend = callPackage ../development/ocaml-modules/psmt2-frontend { };

        psq = callPackage ../development/ocaml-modules/psq { };

        ptime = callPackage ../development/ocaml-modules/ptime { };

        ptmap = callPackage ../development/ocaml-modules/ptmap { };

        ptset = callPackage ../development/ocaml-modules/ptset { };

        pulseaudio = callPackage ../development/ocaml-modules/pulseaudio {
          inherit (pkgs) pulseaudio;
        };

        pure-html = callPackage ../development/ocaml-modules/dream-html/pure.nix { };

        pure-splitmix = callPackage ../development/ocaml-modules/pure-splitmix { };

        pyml = callPackage ../development/ocaml-modules/pyml { };

        ### Q ###

        qcheck = callPackage ../development/ocaml-modules/qcheck { };

        qcheck-alcotest = callPackage ../development/ocaml-modules/qcheck/alcotest.nix { };

        qcheck-core = callPackage ../development/ocaml-modules/qcheck/core.nix { };

        qcheck-lin = callPackage ../development/ocaml-modules/qcheck/lin.nix { };

        qcheck-multicoretests-util =
          callPackage ../development/ocaml-modules/qcheck/multicoretests-util.nix
            { };

        qcheck-ounit = callPackage ../development/ocaml-modules/qcheck/ounit.nix { };

        qcheck-stm = callPackage ../development/ocaml-modules/qcheck/stm.nix { };

        qtest = callPackage ../development/ocaml-modules/qtest { };

        ### R ###

        randomconv = callPackage ../development/ocaml-modules/randomconv { };

        raylib = callPackage ../development/ocaml-modules/raylib { };

        raygui = callPackage ../development/ocaml-modules/raylib/raygui.nix { };

        rdbg = callPackage ../development/ocaml-modules/rdbg { };

        re = callPackage ../development/ocaml-modules/re { };

        react = callPackage ../development/ocaml-modules/react { };

        reactivedata = callPackage ../development/ocaml-modules/reactivedata { };

        readline = callPackage ../development/ocaml-modules/readline {
          readline = pkgs.readline;
        };

        reanalyze = callPackage ../development/tools/ocaml/reanalyze { };

        reason = callPackage ../development/compilers/reason { };

        reason-native = lib.recurseIntoAttrs (callPackage ../development/ocaml-modules/reason-native { });

        reason-react = callPackage ../development/ocaml-modules/reason-react { };
        reason-react-ppx = callPackage ../development/ocaml-modules/reason-react/ppx.nix { };

        rebez = callPackage ../development/ocaml-modules/rebez { };

        redis = callPackage ../development/ocaml-modules/redis/default.nix { };

        redis-lwt = callPackage ../development/ocaml-modules/redis/lwt.nix { };

        reperf = callPackage ../development/ocaml-modules/reperf { };

        repr = callPackage ../development/ocaml-modules/repr { };

        res = callPackage ../development/ocaml-modules/res { };

        resource-pooling = callPackage ../development/ocaml-modules/resource-pooling { };

        result = callPackage ../development/ocaml-modules/ocaml-result { };

        rfc7748 = callPackage ../development/ocaml-modules/rfc7748 { };

        ringo = callPackage ../development/ocaml-modules/ringo { };

        rio = callPackage ../development/ocaml-modules/rio { };

        riot = callPackage ../development/ocaml-modules/riot { };

        rock = callPackage ../development/ocaml-modules/rock { };

        rope = callPackage ../development/ocaml-modules/rope { };

        rosetta = callPackage ../development/ocaml-modules/rosetta { };

        routes = callPackage ../development/ocaml-modules/routes { };

        rpclib = callPackage ../development/ocaml-modules/rpclib { };

        rpclib-lwt = callPackage ../development/ocaml-modules/rpclib/lwt.nix { };

        rresult = callPackage ../development/ocaml-modules/rresult { };

        rtop = callPackage ../development/compilers/reason/rtop.nix { };

        rusage = callPackage ../development/ocaml-modules/rusage { };

        ### S ###

        safepass = callPackage ../development/ocaml-modules/safepass { };

        sail = callPackage ../development/ocaml-modules/sail { };

        samplerate = callPackage ../development/ocaml-modules/samplerate { };

        saturn = callPackage ../development/ocaml-modules/saturn { };

        saturn_lockfree = callPackage ../development/ocaml-modules/saturn/lockfree.nix { };

        sawja = callPackage ../development/ocaml-modules/sawja { };

        scfg = callPackage ../development/ocaml-modules/scfg { };

        secp256k1 = callPackage ../development/ocaml-modules/secp256k1 {
          inherit (pkgs) secp256k1;
        };

        secp256k1-internal = callPackage ../development/ocaml-modules/secp256k1-internal { };

        sedlex = callPackage ../development/ocaml-modules/sedlex { };

        sel = callPackage ../development/ocaml-modules/sel { };

        semaphore-compat = callPackage ../development/ocaml-modules/semaphore-compat { };

        semver = callPackage ../development/ocaml-modules/semver { };

        sendmail = callPackage ../development/ocaml-modules/colombe/sendmail.nix { };

        seq = callPackage ../development/ocaml-modules/seq { };

        seqes = callPackage ../development/ocaml-modules/seqes { };

        sha = callPackage ../development/ocaml-modules/sha { };

        shared-memory-ring = callPackage ../development/ocaml-modules/shared-memory-ring { };

        shared-memory-ring-lwt = callPackage ../development/ocaml-modules/shared-memory-ring/lwt.nix { };

        shine = callPackage ../development/ocaml-modules/shine {
          inherit (pkgs) shine;
        };

        simple-diff = callPackage ../development/ocaml-modules/simple-diff { };

        slug = callPackage ../development/ocaml-modules/slug { };

        smtml = callPackage ../development/ocaml-modules/smtml {
          mdx = mdx.override { inherit logs; };
        };

        sodium = callPackage ../development/ocaml-modules/sodium { };

        sosa = callPackage ../development/ocaml-modules/sosa { };

        soundtouch = callPackage ../development/ocaml-modules/soundtouch {
          inherit (pkgs) soundtouch;
        };

        spdx_licenses = callPackage ../development/ocaml-modules/spdx_licenses { };

        speex = callPackage ../development/ocaml-modules/speex {
          inherit (pkgs) speex;
        };

        spelll = callPackage ../development/ocaml-modules/spelll { };

        spices = callPackage ../development/ocaml-modules/spices { };

        srt = callPackage ../development/ocaml-modules/srt {
          inherit (pkgs) srt;
        };

        ssl = callPackage ../development/ocaml-modules/ssl { };

        stdcompat = callPackage ../development/ocaml-modules/stdcompat { };

        stdint = callPackage ../development/ocaml-modules/stdint { };

        stdlib-random = callPackage ../development/ocaml-modules/stdlib-random { };

        stdlib-shims = callPackage ../development/ocaml-modules/stdlib-shims { };

        stdune = callPackage ../development/ocaml-modules/stdune { };

        stog = callPackage ../applications/misc/stog { };
        stog_asy = callPackage ../applications/misc/stog/asy.nix { };
        stog_markdown = callPackage ../applications/misc/stog/markdown.nix { };

        streaming = callPackage ../development/ocaml-modules/streaming { };

        stringext = callPackage ../development/ocaml-modules/stringext { };

        swhid_core = callPackage ../development/ocaml-modules/swhid_core { };

        synchronizer = callPackage ../development/ocaml-modules/synchronizer { };

        syslog = callPackage ../development/ocaml-modules/syslog { };

        syslog-message = callPackage ../development/ocaml-modules/syslog-message { };

        systemd = callPackage ../development/ocaml-modules/systemd { };

        ### T ###

        taglib = callPackage ../development/ocaml-modules/taglib {
          inherit (pkgs) taglib_1;
        };

        tar = callPackage ../development/ocaml-modules/tar { };

        tar-unix = callPackage ../development/ocaml-modules/tar/unix.nix {
          inherit (pkgs) git;
        };

        tar-eio = callPackage ../development/ocaml-modules/tar/eio.nix {
          inherit (pkgs) git;
        };

        tcpip = callPackage ../development/ocaml-modules/tcpip { };

        tcs-lib = callPackage ../development/ocaml-modules/tcs-lib { };

        tdigest = callPackage ../development/ocaml-modules/tdigest { };

        telegraml = callPackage ../development/ocaml-modules/telegraml { };

        telemetry = callPackage ../development/ocaml-modules/telemetry { };

        terminal = callPackage ../development/ocaml-modules/terminal { };

        terminal_size = callPackage ../development/ocaml-modules/terminal_size { };

        terml = callPackage ../development/ocaml-modules/terml { };

        tezos-base58 = callPackage ../development/ocaml-modules/tezos-base58 { };

        tezt = callPackage ../development/ocaml-modules/tezt { };

        theora = callPackage ../development/ocaml-modules/theora { };

        thread-table = callPackage ../development/ocaml-modules/thread-table { };

        timed = callPackage ../development/ocaml-modules/timed { };

        timedesc = callPackage ../development/ocaml-modules/timedesc { };
        timedesc-tzdb = callPackage ../development/ocaml-modules/timedesc/tzdb.nix { };
        timedesc-tzlocal = callPackage ../development/ocaml-modules/timedesc/tzlocal.nix { };

        tiny_httpd = callPackage ../development/ocaml-modules/tiny_httpd { };

        tls = callPackage ../development/ocaml-modules/tls { };

        tls-async = callPackage ../development/ocaml-modules/tls/async.nix { };

        tls-eio = callPackage ../development/ocaml-modules/tls/eio.nix { };

        tls-lwt = callPackage ../development/ocaml-modules/tls/lwt.nix { };

        tls-mirage = callPackage ../development/ocaml-modules/tls/mirage.nix { };

        toml = callPackage ../development/ocaml-modules/toml { };

        topkg = callPackage ../development/ocaml-modules/topkg { };

        torch = callPackage ../development/ocaml-modules/torch {
          torch = pkgs.libtorch-bin;
        };

        trace = callPackage ../development/ocaml-modules/trace { };

        trace-tef = callPackage ../development/ocaml-modules/trace/tef.nix { };

        trie = callPackage ../development/ocaml-modules/trie { };

        tsdl = callPackage ../development/ocaml-modules/tsdl { };

        tsdl-image = callPackage ../development/ocaml-modules/tsdl-image { };

        tsdl-mixer = callPackage ../development/ocaml-modules/tsdl-mixer { };

        tsdl-ttf = callPackage ../development/ocaml-modules/tsdl-ttf { };

        tsort = callPackage ../development/ocaml-modules/tsort { };

        tty = callPackage ../development/ocaml-modules/tty { };

        tuntap = callPackage ../development/ocaml-modules/tuntap { };

        twt = callPackage ../development/ocaml-modules/twt { };

        type_eq = callPackage ../development/ocaml-modules/type_eq { };

        type_id = callPackage ../development/ocaml-modules/type_id { };

        tyre = callPackage ../development/ocaml-modules/tyre { };

        tyxml = callPackage ../development/ocaml-modules/tyxml { };

        tyxml-lwd = callPackage ../development/ocaml-modules/lwd/tyxml-lwd.nix { };

        ### U ###

        ubase = callPackage ../development/ocaml-modules/ubase { };

        uchar = callPackage ../development/ocaml-modules/uchar { };

        uecc = callPackage ../development/ocaml-modules/uecc { };

        ulex = callPackage ../development/ocaml-modules/ulex { };

        unionFind = callPackage ../development/ocaml-modules/unionFind { };

        unisim_archisec = callPackage ../development/ocaml-modules/unisim_archisec { };

        unix-errno = callPackage ../development/ocaml-modules/unix-errno { };

        unstrctrd = callPackage ../development/ocaml-modules/unstrctrd { };

        uri = callPackage ../development/ocaml-modules/uri { };

        uri-sexp = callPackage ../development/ocaml-modules/uri/sexp.nix { };

        uring = callPackage ../development/ocaml-modules/uring { };

        utop = callPackage ../development/tools/ocaml/utop { };

        uucd = callPackage ../development/ocaml-modules/uucd { };

        uucp = callPackage ../development/ocaml-modules/uucp { };

        uuidm = callPackage ../development/ocaml-modules/uuidm { };

        uunf = callPackage ../development/ocaml-modules/uunf { };

        uuseg = callPackage ../development/ocaml-modules/uuseg { };

        uutf = callPackage ../development/ocaml-modules/uutf { };

        uuuu = callPackage ../development/ocaml-modules/uuuu { };

        ### V ###

        vchan = callPackage ../development/ocaml-modules/vchan { };

        vdom = callPackage ../development/ocaml-modules/vdom { };

        vector = callPackage ../development/ocaml-modules/vector { };

        vg = callPackage ../development/ocaml-modules/vg { };

        visitors = callPackage ../development/ocaml-modules/visitors { };

        vlq = callPackage ../development/ocaml-modules/vlq { };

        vorbis = callPackage ../development/ocaml-modules/vorbis { };

        vpl-core = callPackage ../development/ocaml-modules/vpl-core { };

        ### W ###

        wasm = callPackage ../development/ocaml-modules/wasm { };

        wasm_of_ocaml-compiler = callPackage ../development/tools/ocaml/js_of_ocaml/compiler-wasm.nix { };

        wayland = callPackage ../development/ocaml-modules/wayland { };

        webbrowser = callPackage ../development/ocaml-modules/webbrowser { };

        webmachine = callPackage ../development/ocaml-modules/webmachine { };

        wtf8 = callPackage ../development/ocaml-modules/wtf8 { };

        ### X ###

        x509 = callPackage ../development/ocaml-modules/x509 { };

        xdg = callPackage ../development/ocaml-modules/xdg { };

        xenstore = callPackage ../development/ocaml-modules/xenstore { };

        xenstore-tool = callPackage ../development/ocaml-modules/xenstore-tool { };

        xenstore_transport = callPackage ../development/ocaml-modules/xenstore_transport { };

        xml-light = callPackage ../development/ocaml-modules/xml-light { };

        xmlm = callPackage ../development/ocaml-modules/xmlm { };

        xmlplaylist = callPackage ../development/ocaml-modules/xmlplaylist { };

        xtmpl = callPackage ../development/ocaml-modules/xtmpl { };

        xtmpl_ppx = callPackage ../development/ocaml-modules/xtmpl/ppx.nix { };

        xxhash = callPackage ../development/ocaml-modules/xxhash/default.nix { };

        ### Y ###

        yaml = callPackage ../development/ocaml-modules/yaml { };

        yaml-sexp = callPackage ../development/ocaml-modules/yaml/yaml-sexp.nix { };

        yojson = callPackage ../development/ocaml-modules/yojson { };

        yuscii = callPackage ../development/ocaml-modules/yuscii { };

        yuujinchou = callPackage ../development/ocaml-modules/yuujinchou { };

        ### Z ###

        z3 = callPackage ../development/ocaml-modules/z3 {
          inherit (pkgs) z3;
        };

        zarith = callPackage ../development/ocaml-modules/zarith { };

        zed = callPackage ../development/ocaml-modules/zed { };

        zelus = callPackage ../development/ocaml-modules/zelus { };

        zelus-gtk = callPackage ../development/ocaml-modules/zelus-gtk { };

        zipc = callPackage ../development/ocaml-modules/zipc { };

        zmq = callPackage ../development/ocaml-modules/zmq { };

        zmq-lwt = callPackage ../development/ocaml-modules/zmq/lwt.nix { };

        ### _ ###

        _0install-solver = callPackage ../development/ocaml-modules/0install-solver { };

        ### Exceptional packages kept out of order ###

        # Libs

        buildDunePackage = callPackage ../build-support/ocaml/dune.nix { };

        buildOasisPackage = callPackage ../build-support/ocaml/oasis.nix { };

        buildTopkgPackage = callPackage ../build-support/ocaml/topkg.nix { };

        # Apps from all-packages, to be eventually removed

        google-drive-ocamlfuse = callPackage ../applications/networking/google-drive-ocamlfuse { };

        hol_light = callPackage ../applications/science/logic/hol_light {
          camlp5 =
            if lib.versionAtLeast camlp5.version "8.04.00" then
              camlp5.overrideAttrs {
                version = "8.03.2";
                __intentionallyOverridingVersion = true;
              }
            else
              camlp5;
        };

        ### End ###

      }
      // lib.optionalAttrs config.allowAliases {
        biocaml = throw "biocaml has been removed"; # 2025-06-04
        chacha = throw "chacha has been removed because it has been marked as broken since at least November 2024. It is now vendored inside mirage-crypto, consider using that instead."; # Added 2025-10-11
        gd4o = throw "ocamlPackages.gd4o is not maintained, use ocamlPackages.gd instead";
        ocaml-vdom = throw "2023-10-09: ocamlPackages.ocaml-vdom was renamed to ocamlPackages.vdom";
      }
    )).overrideScope
      liftJaneStreet;

in
let
  inherit (pkgs) callPackage;
in
rec {
  inherit mkOcamlPackages;

  ocamlPackages_4_09 = mkOcamlPackages (callPackage ../development/compilers/ocaml/4.09.nix { });

  ocamlPackages_4_10 = mkOcamlPackages (callPackage ../development/compilers/ocaml/4.10.nix { });

  ocamlPackages_4_11 = mkOcamlPackages (callPackage ../development/compilers/ocaml/4.11.nix { });

  ocamlPackages_4_12 = mkOcamlPackages (callPackage ../development/compilers/ocaml/4.12.nix { });

  ocamlPackages_4_13 = mkOcamlPackages (callPackage ../development/compilers/ocaml/4.13.nix { });

  ocamlPackages_4_14 = mkOcamlPackages (callPackage ../development/compilers/ocaml/4.14.nix { });

  ocamlPackages_5_0 = mkOcamlPackages (callPackage ../development/compilers/ocaml/5.0.nix { });

  ocamlPackages_5_1 = mkOcamlPackages (callPackage ../development/compilers/ocaml/5.1.nix { });

  ocamlPackages_5_2 = mkOcamlPackages (callPackage ../development/compilers/ocaml/5.2.nix { });

  ocamlPackages_5_3 = mkOcamlPackages (callPackage ../development/compilers/ocaml/5.3.nix { });

  ocamlPackages_5_4 = mkOcamlPackages (callPackage ../development/compilers/ocaml/5.4.nix { });

  ocamlPackages_latest = ocamlPackages_5_3;

  ocamlPackages = ocamlPackages_5_3;

  # We still have packages that rely on unsafe-string, which is deprecated in OCaml 4.06.0.
  # Below are aliases for porting them to the latest versions of the OCaml 4 series.
  ocamlPackages_4_14_unsafe_string = mkOcamlPackages (
    callPackage ../development/compilers/ocaml/4.14.nix {
      unsafeStringSupport = true;
    }
  );
}
// lib.optionalAttrs config.allowAliases {
  ocamlPackages_4_00_1 = throw "ocamlPackages_4_00_1 has been removed. Please use a newer version of OCaml.";

  ocamlPackages_4_01_0 = throw "ocamlPackages_4_01_0 has been removed. Please use a newer version of OCaml.";

  ocamlPackages_4_02 = throw "ocamlPackages_4_02 has been removed. Please use a newer version of OCaml.";

  ocamlPackages_4_03 = throw "ocamlPackages_4_03 has been removed. Please use a newer version of OCaml.";

  ocamlPackages_4_04 = throw "ocamlPackages_4_04 has been removed. Please use a newer version of OCaml.";

  ocamlPackages_4_05 = throw "ocamlPackages_4_05 has been removed. Please use a newer version of OCaml.";

  ocamlPackages_4_06 = throw "ocamlPackages_4_06 has been removed. Please use a newer version of OCaml.";

  ocamlPackages_4_07 = throw "ocamlPackages_4_07 has been removed. Please use a newer version of OCaml.";

  ocamlPackages_4_08 = throw "ocamlPackages_4_08 has been removed. Please use a newer version of OCaml.";
}
